package com.tn.bo;

import java.util.Date;
import java.util.List;

import javax.persistence.Embedded;
import javax.persistence.Id;
import javax.persistence.Transient;

import com.googlecode.objectify.annotation.Entity;

@Entity
public class CreditMemo {
	@Id
	private String uniqueCreditMemoNumber;
	private String creditMemoNumber;
	private String supplierCreditMemoNumber;
	private String creditMemoDescription;
	private boolean status;
	private String mainSupplierCompany;
	private String remitToSupplierCompany;
	private boolean invoiceBeingReversed;
	private String invoiceNumber;
	private Date creditMemoDate;
	private Date creditMemoCreateDate;
	private Date creditMemoSubmittedDate;
	private String creditMemoComposer;
	private String creditMemoOwner;
	private List<String> creditMemoComments;
	@Embedded
	private List<CreditMemoLineItem> creditMemoLines;
	private Double totalCreditMemoAmount;
	private Currency totalCreditMemoCurrency;
	private Double taxAmount;
	private Double vatAmount;
	private PaymentTerms paymentTerms;
	private String originatingSystem;
	private String originatingCompany;
	@Embedded
	private List<Recipient> recipients;
	private String customField1;
	private String customField2;
	private String customField3;
	private String customField4;
	private String customField5;
	private String customField6;
	private String customField7;
	private String customField8;
	private String supplierNameText;
	private String creditMemoToCompany;
	private String creditMemoToCompanyName;
	private String creditMemoFromCompanyName;
	private List<String> creditmemoAttachmentIds;
	
	private Date lastModifiedDate;
	private String lastModifiedBy;
	
	private int creditMemoVersion;
	
	private String cmStatus;
	
	
	
	public String getCmStatus() {
		return cmStatus;
	}
	public void setCmStatus(String cmStatus) {
		this.cmStatus = cmStatus;
	}

	@Transient
	private String creditMemoXml;
	
	@Transient
	private List<CreditMemo> creditMemoHistory;
	
	
	
	public Date getLastModifiedDate() {
		return lastModifiedDate;
	}
	public void setLastModifiedDate(Date lastModifiedDate) {
		this.lastModifiedDate = lastModifiedDate;
	}
	public String getLastModifiedBy() {
		return lastModifiedBy;
	}
	public void setLastModifiedBy(String lastModifiedBy) {
		this.lastModifiedBy = lastModifiedBy;
	}
	public List<CreditMemo> getCreditMemoHistory() {
		return creditMemoHistory;
	}
	public void setCreditMemoHistory(List<CreditMemo> creditMemoHistory) {
		this.creditMemoHistory = creditMemoHistory;
	}
	public int getCreditMemoVersion() {
		return creditMemoVersion;
	}
	public void setCreditMemoVersion(int creditMemoVersion) {
		this.creditMemoVersion = creditMemoVersion;
	}
	public String getCreditMemoXml() {
		return creditMemoXml;
	}
	public void setCreditMemoXml(String creditMemoXml) {
		this.creditMemoXml = creditMemoXml;
	}
	public String getCreditMemoToCompanyName() {
		return creditMemoToCompanyName;
	}
	public void setCreditMemoToCompanyName(String creditMemoToCompanyName) {
		this.creditMemoToCompanyName = creditMemoToCompanyName;
	}
	public String getCreditMemoFromCompanyName() {
		return creditMemoFromCompanyName;
	}
	public void setCreditMemoFromCompanyName(String creditMemoFromCompanyName) {
		this.creditMemoFromCompanyName = creditMemoFromCompanyName;
	}
	public List<String> getCreditmemoAttachmentIds() {
		return creditmemoAttachmentIds;
	}
	public void setCreditmemoAttachmentIds(List<String> creditmemoAttachmentIds) {
		this.creditmemoAttachmentIds = creditmemoAttachmentIds;
	}
	public String getCreditMemoToCompany() {
		return creditMemoToCompany;
	}
	public void setCreditMemoToCompany(String creditMemoToCompany) {
		this.creditMemoToCompany = creditMemoToCompany;
	}
	public String getSupplierNameText() {
		return supplierNameText;
	}
	public void setSupplierNameText(String supplierNameText) {
		this.supplierNameText = supplierNameText;
	}
	public String getUniqueCreditMemoNumber() {
		return uniqueCreditMemoNumber;
	}
	public void setUniqueCreditMemoNumber(String uniqueCreditMemoNumber) {
		this.uniqueCreditMemoNumber = uniqueCreditMemoNumber;
	}
	public String getCreditMemoNumber() {
		return creditMemoNumber;
	}
	public void setCreditMemoNumber(String creditMemoNumber) {
		this.creditMemoNumber = creditMemoNumber;
	}
	public String getSupplierCreditMemoNumber() {
		return supplierCreditMemoNumber;
	}
	public void setSupplierCreditMemoNumber(String supplierCreditMemoNumber) {
		this.supplierCreditMemoNumber = supplierCreditMemoNumber;
	}
	public String getCreditMemoDescription() {
		return creditMemoDescription;
	}
	public void setCreditMemoDescription(String creditMemoDescription) {
		this.creditMemoDescription = creditMemoDescription;
	}
	public boolean isStatus() {
		return status;
	}
	public void setStatus(boolean status) {
		this.status = status;
	}
	public String getMainSupplierCompany() {
		return mainSupplierCompany;
	}
	public void setMainSupplierCompany(String mainSupplierCompany) {
		this.mainSupplierCompany = mainSupplierCompany;
	}
	public String getRemitToSupplierCompany() {
		return remitToSupplierCompany;
	}
	public void setRemitToSupplierCompany(String remitToSupplierCompany) {
		this.remitToSupplierCompany = remitToSupplierCompany;
	}
	public boolean isInvoiceBeingReversed() {
		return invoiceBeingReversed;
	}
	public void setInvoiceBeingReversed(boolean invoiceBeingReversed) {
		this.invoiceBeingReversed = invoiceBeingReversed;
	}
	public String getInvoiceNumber() {
		return invoiceNumber;
	}
	public void setInvoiceNumber(String invoiceNumber) {
		this.invoiceNumber = invoiceNumber;
	}
	public Date getCreditMemoDate() {
		return creditMemoDate;
	}
	public void setCreditMemoDate(Date creditMemoDate) {
		this.creditMemoDate = creditMemoDate;
	}
	public Date getCreditMemoCreateDate() {
		return creditMemoCreateDate;
	}
	public void setCreditMemoCreateDate(Date creditMemoCreateDate) {
		this.creditMemoCreateDate = creditMemoCreateDate;
	}
	public Date getCreditMemoSubmittedDate() {
		return creditMemoSubmittedDate;
	}
	public void setCreditMemoSubmittedDate(Date creditMemoSubmittedDate) {
		this.creditMemoSubmittedDate = creditMemoSubmittedDate;
	}
	public String getCreditMemoComposer() {
		return creditMemoComposer;
	}
	public void setCreditMemoComposer(String creditMemoComposer) {
		this.creditMemoComposer = creditMemoComposer;
	}
	public String getCreditMemoOwner() {
		return creditMemoOwner;
	}
	public void setCreditMemoOwner(String creditMemoOwner) {
		this.creditMemoOwner = creditMemoOwner;
	}
	public List<String> getCreditMemoComments() {
		return creditMemoComments;
	}
	public void setCreditMemoComments(List<String> creditMemoComments) {
		this.creditMemoComments = creditMemoComments;
	}
	public List<CreditMemoLineItem> getCreditMemoLines() {
		return creditMemoLines;
	}
	public void setCreditMemoLines(List<CreditMemoLineItem> creditMemoLines) {
		this.creditMemoLines = creditMemoLines;
	}
	public Double getTotalCreditMemoAmount() {
		return totalCreditMemoAmount;
	}
	public void setTotalCreditMemoAmount(Double totalCreditMemoAmount) {
		this.totalCreditMemoAmount = totalCreditMemoAmount;
	}
	public Currency getTotalCreditMemoCurrency() {
		return totalCreditMemoCurrency;
	}
	public void setTotalCreditMemoCurrency(Currency totalCreditMemoCurrency) {
		this.totalCreditMemoCurrency = totalCreditMemoCurrency;
	}
	public Double getTaxAmount() {
		return taxAmount;
	}
	public void setTaxAmount(Double taxAmount) {
		this.taxAmount = taxAmount;
	}
	public Double getVatAmount() {
		return vatAmount;
	}
	public void setVatAmount(Double vatAmount) {
		this.vatAmount = vatAmount;
	}
	public PaymentTerms getPaymentTerms() {
		return paymentTerms;
	}
	public void setPaymentTerms(PaymentTerms paymentTerms) {
		this.paymentTerms = paymentTerms;
	}
	public String getOriginatingSystem() {
		return originatingSystem;
	}
	public void setOriginatingSystem(String originatingSystem) {
		this.originatingSystem = originatingSystem;
	}
	public String getOriginatingCompany() {
		return originatingCompany;
	}
	public void setOriginatingCompany(String originatingCompany) {
		this.originatingCompany = originatingCompany;
	}
	public List<Recipient> getRecipients() {
		return recipients;
	}
	public void setRecipients(List<Recipient> recipients) {
		this.recipients = recipients;
	}
	public String getCustomField1() {
		return customField1;
	}
	public void setCustomField1(String customField1) {
		this.customField1 = customField1;
	}
	public String getCustomField2() {
		return customField2;
	}
	public void setCustomField2(String customField2) {
		this.customField2 = customField2;
	}
	public String getCustomField3() {
		return customField3;
	}
	public void setCustomField3(String customField3) {
		this.customField3 = customField3;
	}
	public String getCustomField4() {
		return customField4;
	}
	public void setCustomField4(String customField4) {
		this.customField4 = customField4;
	}
	public String getCustomField5() {
		return customField5;
	}
	public void setCustomField5(String customField5) {
		this.customField5 = customField5;
	}
	public String getCustomField6() {
		return customField6;
	}
	public void setCustomField6(String customField6) {
		this.customField6 = customField6;
	}
	public String getCustomField7() {
		return customField7;
	}
	public void setCustomField7(String customField7) {
		this.customField7 = customField7;
	}
	public String getCustomField8() {
		return customField8;
	}
	public void setCustomField8(String customField8) {
		this.customField8 = customField8;
	}
	
	public String toString(){
		return "uniqueCreditMemoNumber: " + this.uniqueCreditMemoNumber 
				+ "\n CreditMemoNumber: " + this.creditMemoNumber
				+ "\n CreditMemoVersion: " + this.creditMemoVersion;
	}
}
